import { Engine, Stage } from 'babylon-lib/index';
import { UIRootTool } from 'babylon-lib/highly-coupled-component/gui-tool/ui-root-tool';
import { UIContainer } from 'babylon-lib/gui/base/ui-container';
import { MainStageUI } from './ui/main-stage-ui';
import { RawData } from './raw-assets-info';
import * as Data from './data/data';


class AppUI extends UIRootTool {

    protected initializeUIContainers(engine: Engine, stages: Stage[]): UIContainer[] {
        return [
            new MainStageUI(engine, stages[0], this,
                {
                    isOriginalQr: false,
                    appName: RawData.appConfig.name,
                }
            ),
        ];
    }

    public onResetStageButtonClick(stage: Stage): void {
        Data.resetScene.value=true;
    }

    public onResetSightButtonClick(stage: Stage): void {
        Data.resetSight.value=true;
    }

    public onImmersiveButtonClick(stage: Stage): void {
        Data.exitImmersive.value=true;
    }

}


export { AppUI };